package com.andreamerla.petslife;

import android.app.Application;
import com.andreamerla.petslife.manager.GpsTracker;

/**
 * Created by IntelliJ IDEA.
 * User: a.merla
 * Date: 18/07/13
 * Time: 12.18
 */
public class PetsLifeApplication extends Application {
    /**
     * APPLICATION CONTEXT
     */
    private static PetsLifeApplication context;

    public void onCreate() {
        super.onCreate();
        PetsLifeApplication.context = (PetsLifeApplication) getApplicationContext();
    }

    public static PetsLifeApplication getAppContext() {
        return PetsLifeApplication.context;
    }

    @Override
    public void onTerminate() {
        GpsTracker.getInstance().stopGpsTracking();

        super.onTerminate();
    }
}
